#!/bin/bash
rpm -import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
#yum install -y https://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm
#curl -o /etc/yum.repos.d/elrepo.repo http://192.168.50.211/repos/elrepo.repos
#curl -o /etc/yum.repos.d/epel.repo http://192.168.50.211/repos/epel.repos
#yum update -y
yum clean all
yum makecache
yum --disablerepo="*" --enablerepo="elrepo-kernel" list available
yum --enablerepo=elrepo-kernel install -y kernel-ml
sudo awk -F\' '$1=="menuentry " {print i++ " : " $2}' /etc/grub2.cfg
grub2-set-default 0
grub2-mkconfig -o /boot/grub2/grub.cfg
reboot
